/**
 * 项目示例-列表综合搜索
 * Date 2023-5-25 09:33:56
 */
import type { FilterItem } from '@/components/FilterBar/types'

export const deviceOptions: FilterItem[] = [
  // 查询条件
  {
    label: '区域',
    prop: 'region',
    type: 'checkbox',
    defaultValue: [],
    span: 10,
    inputProps: {
      showCheckAll: true,
      options: [

      ]
    },
    events: {
      change: (value: any, evt: any) => {
        console.log(value, evt)
      }
    }
  },
  {
    label: '设备编号',
    prop: 'eqptCode',
    type: 'input',
    span: 5,
    inputProps: {
      placeholder: '请输入设备编号'
    }
  },
  {
    label: '航站楼',
    prop: 'terminal',
    type: 'checkbox',
    defaultValue: [],
    inputProps: {
    },
    events: {
      change: (value: any, evt: any) => {
        console.log(value, evt)
      }
    }
  }
]
export const dialogEditOptions: FilterItem[] = [
  {
    label: '设备编号：', // 后续由接口获取下拉数据
    prop: 'eqptCode',
    type: 'input',
    span: 12,
    inputProps: {
      clearable: true,
      placeholder: '请输入设备编号'
    }
  },
  {
    label: '归属单位：',
    filterable:true,
    prop: 'owners',
    type: 'select',
    span: 12,
    inputProps: {
      placeholder: '请选择归属单位',
      options: [
      ]
    },
    events: {
      change: (value: any, evt: any) => {
        console.log(value, evt)
      }
    }
  },
  {
    label: '设备型号：',
    prop: 'eqptModel',
    type: 'input',
    span: 12,
    inputProps: {
      clearable: true,
      placeholder: '请输入设备型号'
    }
  },
  {
    label: '设备名称：',
    prop: 'eqptName',
    type: 'input',
    span: 12,
    inputProps: {
      clearable: true,
      placeholder: '请输入设备名称'
    }
  },
  {
    label: '使用部门：',
    filterable:true,
    prop: 'useOrgans',
    type: 'select',
    multiple: true,
    span: 12,
    inputProps: {
      placeholder: '请选择使用部门',
      'default-expand-all': true,
      options: []
    },
    events: {
      change: (value: any, evt: any) => {
        console.log(value, evt)
      }
    }
  },
  {
    label: '设备类型：',
    prop: 'eqptType',
    filterable:true,
    type: 'treeSelect',
    span: 12,
    inputProps: {
      'default-expand-all': false,
      placeholder: '请先选择归属单位,再选中设备类型',
      data: [],
      defaultProps: {}
    },
    events: {
      change: (value: any, evt: any) => {
        console.log(value, evt)
      }
    }
  },
  {
    label: '位置：',
    prop: 'position',
    type: 'input',
    span: 12,
    inputProps: {
      clearable: true,
      placeholder: '请输入位置'
    }
  },
  {
    label: '地图坐标：',
    prop: 'coordinate',
    type: 'inputBtn',
    span: 12,
    icon: 'Location',
    isDisabled: true,
    defaultValue: [],
    inputProps: {
      clearable: true
    },
    events: {
      click: (value: any, evt: any) => {
        console.log(value, evt)
      }
    }
  },
  {
    label: '区域',
    filterable:true,
    prop: 'region',
    type: 'select',
    span: 12,
    isDisabled: true,
    inputProps: {
      clearable: true,
      placeholder: '根据地图坐标回显',
      options: [
      ]
    }
  }
]
